# -*- coding: utf-8 -*-

class Handler(object):
    """ Хендлер. """
    def __init__(self, handler_function):
        self.handler = handler_function
    
    def handle(self, object, args=None):
        return self.handler(object, args)
    
    def __call__(self, object, args=None):
        return self.handle(object, args)